﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using ZHDJ.Core.Log;

namespace ZHDJ.Core.Util
{
    public class ExceptionUtil
    {
        /// <summary>
        /// 写日志
        /// </summary>
        /// <param name="action"></param>
        public static void CatchException(Action action)
        {
            try
            {
                action();
            }
            catch (Exception ex)
            {
                //Log4netHelper.WriteLog(ex);
                LogHelper.Error(ex);
            }
        }

    }
}
